<?php
/**
 * Created by Generate Code EMyLink.
 * Date: {date}
 * RootModel
 * NameTable: {table}
 */

class root_model_/**{class}*/ extends DataProvider_EMyLink
{
    /**
     * Attributes
     */
/**{attributes}*/
    /**
     * Method
     */

    /**
     * @return bool
     * method load
     */
    public function load()
    {
        $sql=   'SELECT * FROM ei_history_test_unit '
                .'{where}';

        $result=$this->ExecuteQuery($sql);
        foreach($result as $value)
        {
            /**{load_value}*/
            return true;
        }
        return false;
    }
    /**
     * @return resource
     * method update
     */
    public function update()
    {
        $sql =  'UPDATE {table} SET '

                .'{value_update}'

                .'{where}';

        return $this->ExecuteNonQuery($sql);
    }

    /**
     * @return resource
     * method save
     */
    public function save()
    {
        $sql =  'INSERT INTO {table} ('
                .'{attributes_insert}'
                .')'
                .'VALUES ("{attributes_value});';

        return $this->ExecuteNonQuery($sql);
    }

    /**
     * @return resource
     * method delete
     */
    public function delete()
    {
        $sql =  'DELETE FROM {table} '
                .'{where}';

        return $this->ExecuteNonQuery($sql);
    }
}